3d linear regression python